package com.flybook.system.domain;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.flybook.common.core.domain.BaseEntity;
import com.flybook.common.xss.Xss;

/**
 * 通知公告表 sys_notice
 *
 * @author flybook
 */
public class SysNotice extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 公告ID */
    private String noticeId;

    /** 公告标题 */
    private String noticeTitle;

    /** 通知类型 */
    private Integer noticeType;

    /** 公告类型 */
    private String noticeState;

    /** 通知人员 */
    private String noticeMobiles;

    /** webhook地址 */
    private String noticeWebhook;

    /** 加密字符 */
    private String noticeSecret;

    /** 公告状态（0正常 1关闭） */
    private String status;

    public String getNoticeId()
    {
        return noticeId;
    }

    public void setNoticeId(String noticeId)
    {
        this.noticeId = noticeId;
    }

    public void setNoticeTitle(String noticeTitle)
    {
        this.noticeTitle = noticeTitle;
    }

    @Xss(message = "公告标题不能包含脚本字符")
    @NotBlank(message = "公告标题不能为空")
    @Size(min = 0, max = 50, message = "公告标题不能超过50个字符")
    public String getNoticeTitle()
    {
        return noticeTitle;
    }

    public void setNoticeType(Integer noticeType)
    {
        this.noticeType = noticeType;
    }

    public Integer getNoticeType()
    {
        return noticeType;
    }

    public void setNoticeState(String noticeState)
    {
        this.noticeState = noticeState;
    }

    public String getNoticeState()
    {
        return noticeState;
    }

    public void setNoticeMobiles(String noticeMobiles)
    {
        this.noticeMobiles = noticeMobiles;
    }

    public String getNoticeMobiles()
    {
        return noticeMobiles;
    }

    public void setNoticeWebhook(String noticeWebhook)
    {
        this.noticeWebhook = noticeWebhook;
    }

    public String getNoticeWebhook()
    {
        return noticeWebhook;
    }

    public void setNoticeSecret(String noticeSecret)
    {
        this.noticeSecret = noticeSecret;
    }

    public String getNoticeSecret()
    {
        return noticeSecret;
    }

    public void setStatus(String status)
    {
        this.status = status;
    }

    public String getStatus()
    {
        return status;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("noticeId", getNoticeId())
            .append("noticeTitle", getNoticeTitle())
            .append("noticeType", getNoticeType())
            .append("noticeState", getNoticeState())
            .append("noticeMobiles", getNoticeMobiles())
            .append("noticeWebhook", getNoticeWebhook())
            .append("noticeSecret", getNoticeSecret())
            .append("status", getStatus())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}
